package com.jsleavit.helloandroidcamp;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.Toast;

public class MainActivity extends Activity {

	Button mButton;

    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
        mButton = (Button)findViewById(R.id.button1);
        mButton.setOnClickListener(new OnClickListener(){
        	public void onClick(View v){
        		Toast.makeText(getApplicationContext(), "Trying to open second activity", Toast.LENGTH_SHORT).show();
        	//	setContentView(R.layout.second);
        		startActivity(new Intent(getApplicationContext(), SecondActivity.class));
        	}
        });
    }
}